<?php
/**
 * Created by PhpStorm.
 * User: wenlei
 * Date: 16/5/8
 * Time: 下午8:51
 */

namespace App\Http\Controllers\Console;
use App\Model\Admin;
use Illuminate\Support\Facades\Response;
use Illuminate\Support\Facades\Request;
use App\Http\Controllers\Controller;

class AdminController extends Controller
{
    public function indexAction() {
        return view('console.admin');
    }

    function listAction() {
//        phpinfo();die();
//        $sEcho  = Request::input('sEcho');
//        $offset  = Request::input('iDisplayStart');
//        $limit = Request::input('iDisplayLength');
//        $data = Admin::take(10)->get();
//        var_dump($data);die();
//        $total = Admin::count();
//        return $this->successForJson($data);
        $url='localhost:8000/command/checkdata';
        $this->doRequest($url);
        return $this->successForJson();
    }

}